//角色接口相关的函数
import request from "../../utils/request"


//新建角色
export const newRole = (data) => {
    return request.post("/api/roles/store", data)
}
//角色列表
export const roleList = (params) => {
    return request.get("/api/roles/index", { params })
}
//软删除
export const roledel = (data) => {
    return request.post("/api/roles/destroy", data)
}
//回收角色列表
export const recycle = (params) => {
    return request.get("/api/roles/recycle", { params })
}
//查询单个角色
export const rolesquery = (params) => {
    return request.get("/api/roles/show", {params})
}
//恢复单个角色
export const rolesretrieve = (data) => {
    return request.post("/api/roles/retrieve", data)
}
//批量恢复角色
export const retrieveMore = (data) => {
    return request.post("api/roles/retrieveMore", data)
}
//编辑修改单个角色
export const rolesModify = (data) => {
    return request.post("/api/roles/update", data)
}
//永久删除某个角色
export const delroles = (data) => {
    return request.post("/api/roles/delete", data)
}
//批量永久删除角色
export const delrolesMore = (data) => {
    return request.post("/api/roles/deleteMore", data)
}
//角色启用和禁用
export const changeRole = (data) => {
    return request.post("/api/roles/change_status", data)
}